package com.test.user;

import android.os.Parcel;
import android.os.Parcelable;

import com.google.android.gms.maps.model.LatLng;

public class OwnUser implements Parcelable
{
	private String gcmRegId;
	private String id;
	private String name;
	private String mail;
	private String pwd;
	private String ssnId;
	private LatLng location;
	private boolean isOnline;
	
	public String getGcmRegId()
	{
		return gcmRegId;
	}
	
	public void setGcmRegId(String gcmRegId)
	{
		this.gcmRegId = gcmRegId;
	}
	
	public String getId()
	{
		return id;
	}
	
	public void setId(String id)
	{
		this.id = id;
	}
	
	public String getName()
	{
		return name;
	}
	
	public void setName(String name)
	{
		this.name = name;
	}
	
	public String getMail()
	{
		return mail;
	}
	
	public void setMail(String mail)
	{
		this.mail = mail;
	}
	
	public String getPwd()
	{
		return pwd;
	}
	
	public void setPwd(String pwd)
	{
		this.pwd = pwd;
	}
	
	public String getSsnId()
	{
		return ssnId;
	}
	
	public void setSsnId(String ssnId)
	{
		this.ssnId = ssnId;
	}
	
	public LatLng getLocation()
	{
		return location;
	}
	
	public void setLocation(LatLng location)
	{
		this.location = location;
	}
	
	public boolean isOnline()
	{
		return isOnline;
	}
	
	public void setOnline(boolean isOnline)
	{
		this.isOnline = isOnline;
	}
	
	@Override
	public int describeContents()
	{
		return 0;
	}
	
	public OwnUser()
	{
		
	}
	
	@Override
	public void writeToParcel(Parcel dest, int flags)
	{
		dest.writeString(gcmRegId);
		dest.writeString(id);
		dest.writeString(name);
		dest.writeString(mail);
		dest.writeString(pwd);
		dest.writeString(ssnId);
		dest.writeString(gcmRegId);
		dest.writeString(String.valueOf(isOnline));
	}
	
	private OwnUser(Parcel in)
	{		
		this.gcmRegId = in.readString();
		this.id = in.readString();
		this.name = in.readString();
		this.mail = in.readString();
		this.pwd = in.readString();
		this.ssnId = in.readString();
		this.gcmRegId = in.readString();
		this.isOnline = Boolean.valueOf(in.readString());
	}
	
	public static final Parcelable.Creator<OwnUser> CREATOR = new Parcelable.Creator<OwnUser>()
	{
		
		@Override
		public OwnUser createFromParcel(Parcel source)
		{
			return new OwnUser(source);
		}
		
		@Override
		public OwnUser[] newArray(int size)
		{
			return new OwnUser[size];
		}
	};
}
